import 'package:fish_redux/fish_redux.dart';
import '../../../app_files.dart';

class CommunityListViewState implements Cloneable<CommunityListViewState> {
  int sortIndex = 0;

  List items;
  int currentPage = 1;

  EasyRefreshController refreshController = EasyRefreshController();
  int type = 0;
  String userID;

  @override
  CommunityListViewState clone() {
    return CommunityListViewState()
      ..sortIndex = sortIndex
      ..items = items
      ..currentPage = currentPage
      ..refreshController = refreshController
      ..type = type
      ..userID = userID;
  }
}

CommunityListViewState initState(Map<String, dynamic> args) {
  return CommunityListViewState()
    ..userID = args['userID']
    ..type = args['type'];
}
